#define _CRT_SECURE_NO_WARNINGS
#include <iostream>
#include <vector>

using namespace std;

int pivotIndex(vector<int>& nums) {
    int dp[10010] = { 0 };
    for (int i = 1; i <= nums.size(); ++i)
    {
        dp[i] = dp[i - 1] + nums[i - 1];
    }

    for (int i = 1; i <= nums.size(); ++i)
    {
        int right = dp[nums.size()] - dp[i];
        int left = dp[i - 1];
        if (right == left)
            return i - 1;
    }

    return -1;
}

int main()
{

	return 0;
}